package com.example.boot2mybatis.controller;

import com.example.boot2mybatis.service.TestTranService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
public class TestTranController {

    @Autowired
    private TestTranService testTranService;

    /**
     * 事务隔离级别测试
     * @return
     */
    @RequestMapping("/testt")
    public String testTran(){
        testTranService.testTran();
        return "测试成功！";
    }
}
